package com.nzx.config;

import com.baomidou.mybatisplus.plugins.PaginationInterceptor;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.transaction.annotation.EnableTransactionManagement;

/**
 * 类描述： MybatisPlus配置类
 * @author niezhux
 * @date 2021/11/11 10:20
 */
@EnableTransactionManagement
@Configuration
@MapperScan("com.nzx.**.mapper*")
public class MybatisPlusConfig {

    /** mybatis-plus分页插件 */
    @Bean
    public PaginationInterceptor paginationInterceptor() {

        return new PaginationInterceptor();
    }

}
